package com.example.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.IService;
import com.example.domain.entity.OrderItem;
import com.example.exception.FloraException;
import org.springframework.transaction.annotation.Transactional;

public interface OrderItemService extends IService<OrderItem> {
    OrderItem addOrderItem(OrderItem orderItemDto) throws FloraException;

    IPage<OrderItem> getOrderItem(Long orderId, int pageNum, int pageSize);


    @Transactional(rollbackFor = Exception.class)
    void deleteOrderItem(Long orderId) throws FloraException;
}
